package com.dubbo.service.impl;

import com.dubbo.service.RemoteUserService;
import org.apache.dubbo.config.annotation.Service;
import org.springframework.beans.factory.annotation.Value;


@Service(version = "1.0.0")
public class RemoteUserImpl implements RemoteUserService {
    @Value("${server.port}")
    private Integer port;

//    @Cacheable(value = "user", key = "#root.targetClass + #name", unless = "#result eq null")
    @Override
    public String sayHello(String name) {
        System.out.println("consumer调用了provider");
        return "hi!server port:"+port+";name="+name;
    }
}